package com.nmsl.nurse.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.nmsl.nurse.mapper.MDischargeRecordMapper;
import com.nmsl.nurse.domain.MDischargeRecord;
import com.nmsl.nurse.service.MIDischargeRecordService;

/**
 * 出院记录Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-02-19
 */
@Service
public class MDischargeRecordServiceImpl implements MIDischargeRecordService
{
    @Autowired
    private MDischargeRecordMapper MDischargeRecordMapper;

    /**
     * 查询出院记录
     * 
     * @param dischargeRecordId 出院记录主键
     * @return 出院记录
     */
    @Override
    public MDischargeRecord selectDischargeRecordByDischargeRecordId(Long dischargeRecordId)
    {
        return MDischargeRecordMapper.selectDischargeRecordByDischargeRecordId(dischargeRecordId);
    }

    /**
     * 查询出院记录列表
     * 
     * @param MDischargeRecord 出院记录
     * @return 出院记录
     */
    @Override
    public List<MDischargeRecord> selectDischargeRecordList(MDischargeRecord MDischargeRecord)
    {
        return MDischargeRecordMapper.selectDischargeRecordList(MDischargeRecord);
    }

    /**
     * 新增出院记录
     * 
     * @param MDischargeRecord 出院记录
     * @return 结果
     */
    @Override
    public int insertDischargeRecord(MDischargeRecord MDischargeRecord)
    {
        return MDischargeRecordMapper.insertDischargeRecord(MDischargeRecord);
    }

    /**
     * 修改出院记录
     * 
     * @param MDischargeRecord 出院记录
     * @return 结果
     */
    @Override
    public int updateDischargeRecord(MDischargeRecord MDischargeRecord)
    {
        return MDischargeRecordMapper.updateDischargeRecord(MDischargeRecord);
    }

    /**
     * 批量删除出院记录
     * 
     * @param dischargeRecordIds 需要删除的出院记录主键
     * @return 结果
     */
    @Override
    public int deleteDischargeRecordByDischargeRecordIds(Long[] dischargeRecordIds)
    {
        return MDischargeRecordMapper.deleteDischargeRecordByDischargeRecordIds(dischargeRecordIds);
    }

    /**
     * 删除出院记录信息
     * 
     * @param dischargeRecordId 出院记录主键
     * @return 结果
     */
    @Override
    public int deleteDischargeRecordByDischargeRecordId(Long dischargeRecordId)
    {
        return MDischargeRecordMapper.deleteDischargeRecordByDischargeRecordId(dischargeRecordId);
    }
}
